function newPagination(obj)
{
	var edge = obj.edge == null ? 2 : obj.edge;
	var pageEdge = obj.pageEdge == null ? 4 : obj.pageEdge;
	var otherPageText = obj.otherPageText == null ? '...' : obj.otherPageText;
	var prePageText = obj.prePageText == null ? '&lt;上一页' : obj.prePageText;
	var nextPageText = obj.nextPageText == null ? '下一页&gt;' : obj.nextPageText;
	var thisPage = obj.thisPage;
	var pageCount = obj.pageCount;
	var id = obj.id;
	var func = obj.func;
	if(thisPage == null)
	{
		alert('thisPage不能为空');
		return;
	}
	if(pageCount == null)
	{
		alert('pageCount不能为空');
		return;
	}
	if(id == null)
	{
		alert('id不能为空');
		return;
	}
	if(func == null)
	{
		alert('func不能为空');
		return;
	}
	var realPageCount = (edge + pageEdge) * 2 + 1;
	var html = '';
	var pageHtml = new Array();
	
	var prePage = '';
	if(thisPage > 1)
	{
		prePage = '<a class="page" href="javascript:' + func + '(' + (thisPage - 1) + ')">' + prePageText + '</a>';
	}
	
	if(pageCount <= realPageCount)
	{
		for(var i = 1; i <= pageCount; i++)
		{
			var currentPageStyle = 'background-color:#ffffff';
			if(thisPage == i)
			{
				currentPageStyle = 'background-color:orange;';
			}
			pageHtml.push('<a class="page" style="' + currentPageStyle + '" href="javascript:' + func + '('+ i + ')">' + i + '</a>');
		}
		html = pageHtml.join('');
	}
	else
	{
		var front = new Array();
		var n = 0;
		front.push(thisPage + '');
		var last = thisPage;
		for(var i = thisPage - 1; i >= (edge + 1) && n < pageEdge; i--)
		{
			front.push(i + '');
			n++;
			last = i;
		}
		if(last > (edge + 1))
		{
			front.push(otherPageText);
			for(var i = edge; i >= 1; i--)
			{
				front.push(i + '');
			}
		}
		else
		{
			for(var i = last - 1; i >= 1; i--)
			{
				front.push(i + '');
			}
		}

		var behind = new Array();
		n = 0;
		last = thisPage;
		for(var i = thisPage + 1; i <= pageCount && n < pageEdge; i++)
		{
			behind.push(i + '')
			n++;
			last = i;
		}
		if(last < (pageCount - edge))
		{
			behind.push(otherPageText);
			for(var i = pageCount - edge + 1; i <= pageCount; i++)
			{
				behind.push(i + '');
			}
		}
		else
		{
			for(var i = last + 1; i <= pageCount; i++)
			{
				behind.push(i + '');
			}
		}
		
		var frontLen = front.length;
		var behindLen = behind.length;
		for(var i = frontLen - 1; i >= 0; i--)
		{
			var currentPageStyle = 'background-color:#ffffff';
			if(i == 0)
			{
				currentPageStyle = 'background-color:orange;';
			}
			if(front[i] != otherPageText)
			{
				pageHtml.push('<a class="page" style="' + currentPageStyle + '" href="javascript:' + func + '('+ front[i] + ')">' + front[i] + '</a>');
			}
			else
			{
				pageHtml.push(otherPageText);
			}
		}
		for(var i = 0; i < behindLen; i++)
		{
			if(behind[i] != otherPageText)
			{
				pageHtml.push('<a class="page" href="javascript:' + func + '('+ behind[i] + ')">' + behind[i] + '</a>');
			}
			else
			{
				pageHtml.push(otherPageText);
			}
		}
		
		html = pageHtml.join('');
	}
	
	var nextPage = '';
	if(thisPage < pageCount)
	{
		nextPage = '<a class="page" href="javascript:' + func + '(' + (thisPage + 1) + ')">' + nextPageText + '</a>';
	}
	
	var pagerObj = $('#' + id);
	pagerObj.css('padding', '3px');
	if(isNotNull(html))
	{
		pagerObj.html(prePage + html + nextPage);
	}
	else
	{
		pagerObj.html('没有记录。');
	}
	
	$('.page').bind('mouseover', function(){
		$(this).css('background-color', '#fbd255');
	});
	$('.page').bind('mouseout', function(){
		if((thisPage + '') != $(this).html())
		{
			$(this).css('background-color', '#ffffff');
		}
		else
		{
			$(this).css('background-color', 'orange');
		}
	});
}